package com.translate.web.dependent;

import org.springframework.beans.factory.config.ConfigurableBeanFactory;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Scope;
import org.springframework.stereotype.Component;

import com.jwt.IJwtUtil;
import com.jwt.JwtConfig;
import com.jwt.JwtTokenUtil;

@Component
public class Dependent {

	@Bean(name="jwtUtil")
	@Scope(scopeName = ConfigurableBeanFactory.SCOPE_SINGLETON)
	public IJwtUtil jwtUtil() {
		return new JwtTokenUtil();
	}
	
	@Bean(name="jwtConfig")
	@Scope(scopeName = ConfigurableBeanFactory.SCOPE_SINGLETON)
	public JwtConfig jwtConfig() {
		return new JwtConfig();
	}
}
